import { createRouter, createWebHistory } from "vue-router";
import index from '@/components/index.vue'; 
import login from '@/views/login.vue';
import res from '@/views/res.vue';
import purchase from '@/components/purchase.vue';
import supply from '@/components/supply.vue';
import pdetails from '@/components/purchase_details.vue';
import sdetails from '@/components/supply_details.vue';
import logistics from '@/components/logistics.vue';
import about from '@/components/about.vue';
import news from '@/components/news.vue';
import vipres from '@/components/vipres.vue';
import newsli from '@/components/news-detail.vue';

const routes = [
  { path: '/', name: "index", component: index },
  { path: '/login', name: "login", component: login },
  { path: '/res', name: "res", component: res },
  { path: '/purchase', name: "purchase", component: purchase },
  { path: '/supply', name: "supply", component: supply },
  { path: '/pdetails', name: 'pdetails', component: pdetails },
  { path: '/sdetails', name: 'sdetails', component: sdetails },
  { path: '/logistics', name: 'logistics', component: logistics },
  { path: '/about', name: 'about', component: about },
  { path:'/news',name:'news',component:news },
  { path:'/vipres',name:'vipres',component:vipres },
  { path:'/newsli',name:'newsli',component:newsli}
];

const router = createRouter({
  history: createWebHistory(),
  routes,
})


export default router;